﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using SecurityLib;
namespace QuanLyDeTaiKHCN
{
    public partial class MasterPage : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            Sec_AES _ps=new Sec_AES();
            string st = Request.QueryString["mod"];
            if (st == null)
            {
                TopMenu1.Visible = false;
                TopMenuSub.Visible = true;
            }
            else
            {
                string modid = _ps.Decrypt(st.Replace(" ", "+"), "gold", 128);
                if (modid == "Create")
                {
                    TopMenu1.Visible = false;
                }
                else
                {
                    if (Request.QueryString["id"] !="")
                    {
                        TopMenu1.Visible = true;
                        TopMenuSub.Visible = false;
                    }
                    else
                    {
                        TopMenu1.Visible = false;
                        TopMenuSub.Visible = true;
                    }
                }
            }
        }
    }
}